]> dgit.raspbian.org Git - gnome-shell.git/log
gnome-shell.git
6 years agoextensionPrefs: Move data/sources into subdirectories
Florian Müllner [Sun, 8 Mar 2020 13:50:59 +0000 (14:50 +0100)]
extensionPrefs: Move data/sources into subdirectories

As we will eventually move the code to a subproject, start arranging
it like a top-level srcdir.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1081

6 years agoextensionPrefs: Use imports.package.start()
Florian Müllner [Thu, 5 Mar 2020 16:44:27 +0000 (17:44 +0100)]
extensionPrefs: Use imports.package.start()

We want to make the extensions app code more self-contained to make it
easier to build separately, and ultimately make it available on flathub.

One complication we are facing is that it is currently all over the source
tree:
 - js/extensionPrefs for the main code
 - src for the launcher process
 - data for .desktop file and icons

Switching from a C launcher to the imports.package module allows us to
consolidate the first two, and will also take care of the annoying
setup bits (defining JS search path, extending GI lookup, loading
resources).

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1081

6 years agomodemManager: fixed dbus path for GDBusProxy
Reik Keutterling [Thu, 19 Mar 2020 11:06:26 +0000 (12:06 +0100)]
modemManager: fixed dbus path for GDBusProxy

Fix this runtime error:
JS ERROR: TypeError: this._proxy.SignalQuality is null
_reloadSignalQuality@resource:///org/gnome/shell/misc/modemManager.js:252:34
_init@resource:///org/gnome/shell/misc/modemManager.js:234:14
NMDeviceModem@resource:///org/gnome/shell/ui/status/network.js:517:34
_deviceAdded@resource:///org/gnome/shell/ui/status/network.js:1755:27

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1105

6 years agoUpdate Slovak translation
Peter Mráz [Thu, 19 Mar 2020 06:20:35 +0000 (06:20 +0000)]
Update Slovak translation

6 years agoUpdate Slovak translation
Peter Mráz [Wed, 18 Mar 2020 14:54:25 +0000 (14:54 +0000)]
Update Slovak translation

6 years agoextensionSystem: Catch errors when updating extensions
Florian Müllner [Mon, 9 Mar 2020 15:45:22 +0000 (16:45 +0100)]
extensionSystem: Catch errors when updating extensions

Extension updates are installed at startup, so any errors that bubble
up uncaught will prevent the startup to complete.

While the most likely error reason was addressed in the previous commit
(pending update for a no-longer exitent extension), it makes sense to
catch any kind of corrupt updates to not interfere with shell startup.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/2343

6 years agoextensionDownloader: Remove pending updates with extension
Florian Müllner [Mon, 9 Mar 2020 15:49:34 +0000 (16:49 +0100)]
extensionDownloader: Remove pending updates with extension

When an extension is uninstalled, there is no point in keeping
a pending update: If the update didn't fail (which it currently
does), we would end up sneakily reinstalling the extension.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/2343

6 years agonetworkAgent: Make searching VPN binaries asynchronous
Florian Müllner [Sat, 14 Mar 2020 21:01:00 +0000 (22:01 +0100)]
networkAgent: Make searching VPN binaries asynchronous

Doing blocking IO in a graphical UI is bad, doing it in the compositor
is much much worse. So even if handling VPN requests is a relatively
rare event, doing it asynchronously is better.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/2386

6 years agoshell/network-agent: Wrap nm_plugin_info_new_search_file()
Florian Müllner [Sat, 14 Mar 2020 20:51:33 +0000 (21:51 +0100)]
shell/network-agent: Wrap nm_plugin_info_new_search_file()

While we can use the libnm API directly from JS, the call will
synchronously load the VPN service descriptions from disk.
Previously we were lowering the impact by caching the result,
but as we stopped doing that, it becomes more important to address
the issue properly and move it off to a thread.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/2386

6 years agonetworkAgent: Drop VPN plugin cache
Florian Müllner [Fri, 13 Mar 2020 21:09:33 +0000 (22:09 +0100)]
networkAgent: Drop VPN plugin cache

libnm doesn't only search for plugins in the regular VPN plugin directory,
but also in the legacy location and the directory pointed to by the
NM_VPN_PLUGIN_DIR environment variable (if set).

We don't monitor the additional directories, so it's possible for our cache
to become outdated.

Instead of trying to play catch-up with libnm's internals, do what nm-applet
does and use the appropriate API to look up the plugin on each request.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/2386

6 years agoextensionDownloader: Only check server if there's something to update
Florian Müllner [Sun, 15 Mar 2020 22:41:27 +0000 (23:41 +0100)]
extensionDownloader: Only check server if there's something to update

checkForUpdates() will currently always query the server for updates,
even when passing an empty vardict of installed extensions. We know
there won't be any updates in that case, so avoid a pointless network
request.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1100

6 years agodateMenu: Don't ellipsize world clock time/tz
Florian Müllner [Fri, 13 Mar 2020 14:37:42 +0000 (15:37 +0100)]
dateMenu: Don't ellipsize world clock time/tz

If we need to ellipsize, it should be the location name, not the time
or timezone offset.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1090

6 years agoa11y: Change HC icon theme first
Florian Müllner [Sat, 14 Dec 2019 18:15:53 +0000 (19:15 +0100)]
a11y: Change HC icon theme first

There are two ways for applications to provide a high contrast icon:

 1. install an icon into the HighContrast theme
 2. install a symbolic icon into the default hicolor theme

The latter is preferred nowadays, and implemented in the high-contrast
CSS variant by enforcing the symbolic icon style.

However together with the way we currently enable/disable high-contrast,
this can lead to the following race:
 1. the GTK theme is changed from HighContrast
 2. we reload the default stylesheet
 3. the icon style changes to "regular", so we request a
    new icon from the HighContrast icon theme
 4. the icon theme is changed from HighContrast
 5. we evict existing icons from the cache
 6. we reload icons for the new icon theme; however as we
    find a pending request (from 3), we re-use it
 7. the request from 3 finishes, and we end up with a
    wrong icon in the cache

The simplest fix is to change the icon theme before the GTK theme: Unlike the
theme name, the icon style is encoded in the cache key, so we won't re-use
an old (and incorrect) request in that case.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/2414

6 years agoUpdate Russian translation
Stas Solovey [Sun, 15 Mar 2020 21:14:23 +0000 (21:14 +0000)]
Update Russian translation

6 years agomodemManager: Look for property on correct object
Cosimo Cecchi [Sat, 14 Mar 2020 21:42:43 +0000 (14:42 -0700)]
modemManager: Look for property on correct object

The SignalQuality property is defined on the GDBusProxy, not the modem
JS object.
Fix this runtime warning:

JS WARNING: [resource:///org/gnome/shell/misc/modemManager.js 252]: reference to undefined property "SignalQuality"
JS ERROR: TypeError: this.SignalQuality is undefined
_reloadSignalQuality@resource:///org/gnome/shell/misc/modemManager.js:252:34
_init@resource:///org/gnome/shell/misc/modemManager.js:234:14
NMDeviceModem@resource:///org/gnome/shell/ui/status/network.js:517:34
_deviceAdded@resource:///org/gnome/shell/ui/status/network.js:1755:27

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1097

6 years agojs: Always use AppSystem to lookup apps
Florian Müllner [Sat, 14 Mar 2020 13:45:42 +0000 (14:45 +0100)]
js: Always use AppSystem to lookup apps

There is no good reason for bypassing the application cache in
AppSystem and loading .desktop files again.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1093

6 years agocalendar: Adjust for evolution changes
Florian Müllner [Sat, 14 Mar 2020 13:45:42 +0000 (14:45 +0100)]
calendar: Adjust for evolution changes

When launching the default calendar application, we special-case
evolution to make sure it starts up with the calendar component.

This is currently broken in two ways:

 - evolution changed its .desktop file to use reverse DNS notation

 - as evolution can now be distributed via flatpak, we can no longer
   assume that 'evolution-calendar.desktop' exists when evolution does
   (even though we ship the .desktop file ourselves, it is considered
   invalid if the executable isn't found)

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1093

6 years agomain: Unwatch notification proxy name after auto-start
Florian Müllner [Thu, 12 Mar 2020 22:23:37 +0000 (23:23 +0100)]
main: Unwatch notification proxy name after auto-start

We only "watch" the 'org.gnome.Shell.Notifications' name to start the
service, not to actually monitor name owner changes; so unwatch the
name once that's done.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/2381

6 years agomain: Activate notification proxy on start
Florian Müllner [Wed, 4 Mar 2020 01:35:21 +0000 (02:35 +0100)]
main: Activate notification proxy on start

At least for the time being, this looks like the easiest option to
launch the service:

 - we could add a systemd unit, but then we'd need to update the
   RequiredComponents in the fallback session definition as well,
   making it necessary for gnome-shell, gnome-shell-extensions and
   gnome-session to be updated to 3.36.1 in lockstep

 - autostart is problematic as it would make gnome-shell conflict
   with other notification daemons; also autostart is most useful
   with automatic shutdown, which would require tracking signal
   subscriber to determine when the service is unused

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/547

6 years agodbusServices/notifications: Add a separate notification daemon
Florian Müllner [Thu, 16 May 2019 19:08:06 +0000 (21:08 +0200)]
dbusServices/notifications: Add a separate notification daemon

Add a small service that exposes the Fdo notification API under the
well-known name, and forwards any requests to the actual implementation
in the shell.

That way any app with permission to talk to org.freedesktop.Notifications
will get exactly that, and nothing more.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/547

6 years agomain: Stop owning the public org.freedesktop.Notifications name
Florian Müllner [Thu, 16 May 2019 17:30:35 +0000 (19:30 +0200)]
main: Stop owning the public org.freedesktop.Notifications name

For sandboxed apps, permission to talk to org.freedesktop.Notifications
looks innocent enough. However as all exported services share the same
connection to the session bus, that permission actually grants an app
access to *any* shell D-Bus API.

While we want apps to use the notification portal, it is still common
for apps to use libnotify, raw D-Bus calls or even notify-send.

We don't want to give those apps a way to circumvent most of the sandbox
restrictions, so stop owning the org.freedesktop.Notifications name.

In a next step we will implement a separate notification-daemon that
exposes the API on the well-known address and proxies any requests to
the real implementation in gnome-shell.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/547

6 years agodbusServices: Add some base classes for small stand-alone services
Florian Müllner [Wed, 4 Mar 2020 02:06:57 +0000 (03:06 +0100)]
dbusServices: Add some base classes for small stand-alone services

There are a couple of D-Bus services that are currently provided by
gnome-shell for which it makes sense to move them fully or partially
into separate processes:

 - screen recording (performance)
 - FDO notifications (security)
 - Extensions (portalization)

Add some base classes and build system glue to take care of the
common boilerplate.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/547

6 years agoapp-cache: add ShellAppCache for GAppInfo caching
Christian Hergert [Fri, 28 Feb 2020 03:36:14 +0000 (19:36 -0800)]
app-cache: add ShellAppCache for GAppInfo caching

This caches GAppInfo so that the compositor thread does not have to perform
costly disk access to load them. Instead, they are loaded from a worker
thread and the ShellAppCache notifies of changes.

To simplify maintenance, ShellAppCache manages this directly and the
existing ShellAppSystem wraps the cache. We may want to graft these
together in the future, but now it provides the easiest way to backport
changes to older Shell releases.

Another source of compositor thread disk access was in determining the
name for an application directory. Translations are provided via GKeyFile
installed in "desktop-directories". Each time we would build the name
for a label (or update it) we would have to load all of these files.

Instead, the ShellAppCache caches that information and updates the cache
in bulk when those change. We can reduce this in the future to do less
work, but chances are these will come together anyway so that is probably
worth fixing if we ever come across it.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/2282

6 years agoSt: Ensure to update entry hint visibility with IM preedit
Carlos Garnacho [Wed, 11 Mar 2020 11:32:07 +0000 (12:32 +0100)]
St: Ensure to update entry hint visibility with IM preedit

Commit 88ac339774 changed StEntry behavior so the text hint would
stay visible while focused, as long as the text buffer is empty.
However, IMs that use preedit still should count as "started typing",
while the text buffer is still officially empty.

To fix this, check on st_entry_update_hint_visibility() that there's
indeed no preedit buffer before showing the hint. We can't directly
listen to internal preedit buffer changes in ClutterText, so handle
preedit buffer updates through the ::cursor-changed signal that will
be indirectly emitted.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1084

6 years agowindowManager: Do not shutdown ibus/xsettings on X11 compositor restart
Carlos Garnacho [Tue, 10 Mar 2020 12:23:17 +0000 (13:23 +0100)]
windowManager: Do not shutdown ibus/xsettings on X11 compositor restart

These paths are meant for Xwayland, not for X11 compositors being restarted
through alt-f2 + r. Maybe some signal analogous to init-xserver should be
added for Xwayland shutdown paths, but this signal we are currently
listening for is backend agnostic.

Closes: https://gitlab.gnome.org/GNOME/gnome-shell/issues/2329
6 years agoibusManager: fix ibus launch error because of wrong method name
Alynx Zhou [Mon, 9 Mar 2020 02:09:47 +0000 (10:09 +0800)]
ibusManager: fix ibus launch error because of wrong method name

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1080

6 years agoUpdate German translation
Tim Sabsch [Mon, 9 Mar 2020 22:40:48 +0000 (22:40 +0000)]
Update German translation

6 years agost/texture-cache: Fix invalid memory write related to X11 window icons
Sebastian Keller [Mon, 9 Mar 2020 01:17:19 +0000 (02:17 +0100)]
st/texture-cache: Fix invalid memory write related to X11 window icons

st_texture_cache_bind_weak_notify calls g_clear_signal_handler which
then calls st_texture_cache_free_bind. st_texture_cache_free_bind frees
the bind structure, so by the time g_clear_signal_handler tries to write
bind->notify_signal_id, bind has already been freed.

Fix this by using g_signal_handler_disconnect instead.

This partially reverts 135d178d08

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/issues/2334

6 years agoUpdate Norwegian Bokmål translation
Kjartan Maraas [Mon, 9 Mar 2020 15:40:01 +0000 (15:40 +0000)]
Update Norwegian Bokmål translation

6 years agoUpdate Czech translation
Daniel Rusek [Mon, 9 Mar 2020 15:18:03 +0000 (15:18 +0000)]
Update Czech translation

6 years agofileUtils: Remove some compatibility code
Florian Müllner [Sat, 7 Mar 2020 18:28:48 +0000 (19:28 +0100)]
fileUtils: Remove some compatibility code

The condition was added to keep working with the then-stable version
of gjs. We already require a more recent version now, so the compat
code is effectively dead.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1077

6 years agojs: Remove unused files from resources
Florian Müllner [Sat, 7 Mar 2020 13:18:08 +0000 (14:18 +0100)]
js: Remove unused files from resources

fileUtils hasn't used Params since 2013, but was still importing it
until commit a1534dab0264 ...

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1077

6 years agoUpdate Japanese translation
sicklylife [Mon, 9 Mar 2020 12:47:10 +0000 (12:47 +0000)]
Update Japanese translation

6 years agoUpdated Czech translation
Marek Černocký [Mon, 9 Mar 2020 12:45:33 +0000 (13:45 +0100)]
Updated Czech translation

6 years agoUpdate Japanese translation
sicklylife [Mon, 9 Mar 2020 12:35:24 +0000 (12:35 +0000)]
Update Japanese translation

6 years agost/password-entry: Fix peek icon leak
Sebastian Keller [Sun, 8 Mar 2020 22:51:55 +0000 (23:51 +0100)]
st/password-entry: Fix peek icon leak

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1078

6 years agoUpdate Catalan translation
Jordi Mas [Sun, 8 Mar 2020 20:56:30 +0000 (21:56 +0100)]
Update Catalan translation

6 years agoUpdate Serbian translation
Марко Костић [Sun, 8 Mar 2020 20:21:47 +0000 (20:21 +0000)]
Update Serbian translation

6 years agoextensionPrefs: Stop escaping extension name
Florian Müllner [Tue, 3 Mar 2020 23:26:04 +0000 (00:26 +0100)]
extensionPrefs: Stop escaping extension name

The corresponding label no longer uses markup, so we can and should use
the unescaped name.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/2305

6 years agoappDisplay: Reload folder views on installed app changes
Jonas Dreßler [Mon, 17 Feb 2020 15:21:58 +0000 (16:21 +0100)]
appDisplay: Reload folder views on installed app changes

Since the FolderViews are not connected to the "installed-changed"
signal, we need to reload their apps by calling _redisplay() when an app
is removed or installed. We can't connect to "installed-changed" inside
FolderView because we need to ensure _redisplay() of the FolderView is
called before AppView tries to access the apps of the folder inside
_refilterApps(). So reload the FolderViews inside AllViews _redisplay()
implementation to ensure everything is up to date before accessing the
apps of the folder.

Since the "apps-changed" signal of FolderIcon now indirectly triggers a
_redisplay() of the FolderViews, the 'changed' handler of FolderView is
now redundant and can be removed. Because of this, we also need to move
the emission of the "apps-changed" signal to the start of the signal
handler to make sure the view is updated before we try to access items
of the view.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/issues/1901

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1011

6 years agoappDisplay: Disconnect folder "changed" signal when actors are destroyed
Jonas Dreßler [Mon, 17 Feb 2020 14:40:55 +0000 (15:40 +0100)]
appDisplay: Disconnect folder "changed" signal when actors are destroyed

We should disconnect the folders "changed" signal from the folder in
case the FolderView or FolderIcon is destroyed. While at it, also remove
the unused this._spaceReadySignalId of FolderIcon.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1011

6 years agoappDisplay: Implement an addApp() method for FolderViews
Jonas Dreßler [Mon, 17 Feb 2020 15:56:10 +0000 (16:56 +0100)]
appDisplay: Implement an addApp() method for FolderViews

Similar to removeApp(), implement addApp() in FolderView to make adding
folders to views a bit more obvious.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1011

6 years agoappDisplay: Rename _redisplay() functions unrelated to BaseAppView
Jonas Dreßler [Mon, 17 Feb 2020 14:35:49 +0000 (15:35 +0100)]
appDisplay: Rename _redisplay() functions unrelated to BaseAppView

The _redisplay() function is usally used for subclasses of BaseAppView
which want to implement their own _redisplay() function, having that
function name in two classes which have nothing to do with BaseAppView
can be quite confusing. Make those names less confusing and call the
functions  _sync() and _rebuildMenu() instead.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1011

6 years agoappDisplay: Add back background color for folder icons
Jonas Dreßler [Sun, 16 Feb 2020 20:56:27 +0000 (21:56 +0100)]
appDisplay: Add back background color for folder icons

During this cycle the background color of the folder icons was removed
(probably fallout from the theme refactor), this was not intended
design-wise, so add it back.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1011

6 years agoappDisplay: Properly hide overlay scrollbar in folders
Jonas Dreßler [Sun, 16 Feb 2020 20:55:39 +0000 (21:55 +0100)]
appDisplay: Properly hide overlay scrollbar in folders

Use the scroll-view policy ST_POLICY_EXTERNAL to hide the scrollbar
instead of setting its css properties to hidden, where it can still be
clicked but isn't visible.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1011

6 years agoappDisplay: Remove the top padding from folder app grid
Jonas Dreßler [Mon, 17 Feb 2020 13:21:51 +0000 (14:21 +0100)]
appDisplay: Remove the top padding from folder app grid

There already is a bottom padding defined for the name container of the
folder, so remove the top padding of the appGrid and make sure we can
show a few more icons inside the folder.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1011

6 years agoappDisplay: Take the viewBox into account for the contentBox of folders
Jonas Dreßler [Mon, 17 Feb 2020 13:12:47 +0000 (14:12 +0100)]
appDisplay: Take the viewBox into account for the contentBox of folders

The viewBox has a border applied, so when we call adaptToSize using only
the content box of the container, the width of the border is not removed
from the content box and the grid will be allocated less space than what
we told it before using adaptToSize.

Fix that by adjusting the content box for the size of the viewBox, too.
This makes sure the correct amount of columns can be shown inside a
folder, since right now we only show 3 colums even though 4 would fit.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1011

6 years agobuild: Fix some harmless compiler warnings
Florian Müllner [Mon, 2 Mar 2020 17:16:25 +0000 (18:16 +0100)]
build: Fix some harmless compiler warnings

Some (newer?) GCC versions complain when a g_auto variable isn't
initialized when declared, even when the initialization is guaranteed
to happen before the variable is used or goes out of scope.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/2298

6 years agoBump extensions-tool version as well
Florian Müllner [Sun, 8 Mar 2020 00:21:49 +0000 (01:21 +0100)]
Bump extensions-tool version as well

6 years agoBump version to 3.36.0
Florian Müllner [Sat, 7 Mar 2020 21:47:10 +0000 (22:47 +0100)]
Bump version to 3.36.0

Update NEWS.

6 years agoUpdate Dutch translation
Nathan Follens [Sat, 7 Mar 2020 21:50:08 +0000 (21:50 +0000)]
Update Dutch translation

6 years agoslider: Include handle border radius when calculating center offset
Jonas Dreßler [Sun, 1 Mar 2020 13:01:14 +0000 (14:01 +0100)]
slider: Include handle border radius when calculating center offset

Since 38da479ee we correctly ceil the non-integer radius of the slider
handle when calculating the offset for drawing the circle. Since the
handle also has a border with a width of 1px by default, we should also
factor that in when calculating the offset.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/issues/1569

6 years agoTheme: colorize .folder-namel-label
ub [Tue, 3 Mar 2020 11:47:21 +0000 (11:47 +0000)]
Theme: colorize .folder-namel-label

- so it receives the correct color, independent from the theme $variant (light/dark)

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1059

6 years agolocation: Update desktop file name for privacy settings
Sebastian Keller [Wed, 4 Mar 2020 22:24:18 +0000 (23:24 +0100)]
location: Update desktop file name for privacy settings

The location settings have been moved to their own panel with a
different desktop file:
https://gitlab.gnome.org/GNOME/gnome-control-center/-/commit/f92f6f5c

Fixes https://gitlab.gnome.org/GNOME/gnome-shell/issues/2316

6 years agomain: Get the theme resource name from sessionMode
Marco Trevisan (Treviño) [Tue, 3 Mar 2020 09:05:54 +0000 (10:05 +0100)]
main: Get the theme resource name from sessionMode

Along the lines of `styleSheetName`, a session mode may want to provide its
own gresource file, so make this possible via a `themeResourceName` session
mode parameter, defaulted to gnome-shell-theme.gresource

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1063

6 years agoshellDBus: Add new OpenExtensionPrefs method
Florian Müllner [Thu, 5 Mar 2020 01:00:57 +0000 (02:00 +0100)]
shellDBus: Add new OpenExtensionPrefs method

Unlike any other methods in the Extensions API, LaunchExtensionPrefs()
opens what appears to be an application dialog, except that it is
really a separate application that the caller has no control over.

In order to address that, add a new OpenExtensionPrefs() method that
takes additional parameters (modelled after the desktop portal APIs)
that will make it possible to improve the behavior in the future.

The new parameters are ignored for now, but pushing the API out now
will allow us to fill in the functionality post the .0 release.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1074

6 years agoshellDBus: Add UserExtensionsEnabled property
Florian Müllner [Thu, 5 Mar 2020 17:15:37 +0000 (18:15 +0100)]
shellDBus: Add UserExtensionsEnabled property

The 'disable-user-extensions' GSettings key is the last extensions-related
setting that isn't exposed over D-Bus, and therefore requires consumers
to access the GSettings directly.

Expose the setting as UserExtensionsEnabled readwrite property in the
org.gnome.Shell.Extensions interface to allow consumers to manage
extensions purely via D-Bus.

The 'disable-user-extensions' setting is the last extension-related
bit from the org.gnome.shell GSettings schema that is not exposed
via D-Bus.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1074

6 years agoibusManager: Ensure to spawn --xim on non-wayland sessions
Carlos Garnacho [Wed, 4 Mar 2020 16:52:27 +0000 (17:52 +0100)]
ibusManager: Ensure to spawn --xim on non-wayland sessions

This (mistakenly) now only depends on signals triggered on Wayland
sessions. Hardcoding the XIM support on X11 sessions will make input
in some clients work again.

Closes: https://gitlab.gnome.org/GNOME/gnome-shell/issues/1690
6 years agowindowManager: X11 can work without gsd-xsettings
Olivier Fourdan [Tue, 3 Mar 2020 12:14:23 +0000 (13:14 +0100)]
windowManager: X11 can work without gsd-xsettings

Currently, a failure to start the Systemd unit `gsd-xsettings.target`
would be considered a failure to start Xwayland.

That means that if `gsd-xsettings.target` fails to start for whatever
reason, no X11 client can be used on Wayland.

However, XSettings is by no mean mandatory for X11 clients and many
legacy X11 clients do not implement XSettings. Those who do always have
a fallback path and therefore can still work without XSettings.

Make a failure to start the Systemd unit `gsd-xsettings.target` non
blocking for Xwayland, and just log a warning message.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1065

6 years agoshell/tray-manager: Delay managing screen if necessary
Florian Müllner [Wed, 4 Mar 2020 13:27:54 +0000 (14:27 +0100)]
shell/tray-manager: Delay managing screen if necessary

Now that Xwayland startup is asynchronous, the function may be called
before X11 is available, resulting in a crash.

Fix this by only managing the tray immediately if we already have an
X11 display, and wait for it to be set up otherwise.

Likewise, unmanage the screen when X11 becomes unavailable.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/2308

6 years agoshell/tray-manager: Allow to unmanage screen
Florian Müllner [Wed, 4 Mar 2020 22:26:15 +0000 (23:26 +0100)]
shell/tray-manager: Allow to unmanage screen

Since support for legacy status icons is implemented by extensions
nowadays, they need to undo the call to manage_screen() when they
are disabled.

Right now that means bypassing garbage collection with an explicit
call to run_dispose() on the Shell.TrayManager. That works, but is
rather ugly.

An explicit unmanage_screen() method is a nicer option, and will be
useful to us as well to deal with X11 going away (once Xwayland
crashes don't bring down the entire session).

https://gitlab.gnome.org/GNOME/gnome-shell/issues/2308

6 years agoshell/tray-manager: Only create resources when needed
Florian Müllner [Wed, 4 Mar 2020 22:12:29 +0000 (23:12 +0100)]
shell/tray-manager: Only create resources when needed

NaTrayManager in particular is deeply tied to X11. We currently assume
that X11 support is always available, but that is already not true
anymore - Xwayland startup is now asynchronous.

It will be even less true once we handle Xwayland crashes gracefully.

Start addressing that by not creating the corresponding resources once
and assume they exist for the lifetime of Shell.TrayManager, but make
sure they exist when actually needed.

https://gitlab.gnome.org/GNOME/gnome-shell/issues/2308

6 years agoUpdated Czech translation
Marek Černocký [Fri, 6 Mar 2020 17:25:26 +0000 (18:25 +0100)]
Updated Czech translation

6 years agoUpdate Japanese translation
sicklylife [Wed, 4 Mar 2020 21:53:07 +0000 (21:53 +0000)]
Update Japanese translation

6 years agoUpdate Ukrainian translation
Daniel Korostil [Wed, 4 Mar 2020 16:47:03 +0000 (16:47 +0000)]
Update Ukrainian translation

6 years agoUpdate Italian translation
Milo Casagrande [Tue, 3 Mar 2020 08:09:27 +0000 (08:09 +0000)]
Update Italian translation

6 years agoenvironment: Fix date conversion
Florian Müllner [Mon, 2 Mar 2020 12:46:04 +0000 (13:46 +0100)]
environment: Fix date conversion

This is a regression from commit 06b690ff21204:

GLib.DateTime.new() expects the full four-digit year, so passing
the abbreviated year from Date() will result in a bogus datetime.

Today is *not* Saturday March 2nd, 120 ...

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1061

6 years agoUpdated Lithuanian translation
Aurimas Černius [Sun, 1 Mar 2020 18:41:32 +0000 (20:41 +0200)]
Updated Lithuanian translation

6 years agoUpdate Croatian translation
Goran Vidović [Sun, 1 Mar 2020 15:47:17 +0000 (15:47 +0000)]
Update Croatian translation

6 years agoUpdate Punjabi translation
Aman Alam [Sun, 1 Mar 2020 09:18:00 +0000 (09:18 +0000)]
Update Punjabi translation

6 years agoBump version to 3.35.92
Florian Müllner [Sun, 1 Mar 2020 01:09:03 +0000 (02:09 +0100)]
Bump version to 3.35.92

Update NEWS.

6 years agounlockDialog: Transition switch-user button with prompt
Florian Müllner [Wed, 19 Feb 2020 13:30:05 +0000 (14:30 +0100)]
unlockDialog: Transition switch-user button with prompt

We ended up always showing the switch-user button on the lock screen,
as showing and hiding it with the prompt was too visually distracting.

But now that we have a fancy transition in place, we can easily extend
it to the switch-user button as well.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1029

6 years agounlockDialog: Simplify sensitivity handling
Florian Müllner [Wed, 19 Feb 2020 13:24:51 +0000 (14:24 +0100)]
unlockDialog: Simplify sensitivity handling

We only call _updateSensitivity() to make elements sensitive, and
nothing ever touches the sensitivity of the switch-user button; so
just call the corresponding authPrompt method directly, which is the
only bit that has an actual effect.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1029

6 years agowindowManager: Fix shutdown signal connection
Carlos Garnacho [Sat, 29 Feb 2020 22:42:29 +0000 (23:42 +0100)]
windowManager: Fix shutdown signal connection

This signal relied on mutter changes that were withdrawn
and it was unintended to use here. Restore the usage of
good old MetaDisplay::x11-display-closing.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1056

6 years agowindowManager: Implement MetaDisplay::init-xserver hook
Carlos Garnacho [Thu, 14 Nov 2019 22:56:42 +0000 (23:56 +0100)]
windowManager: Implement MetaDisplay::init-xserver hook

We do spawn gsd-xsettings, and watch its name before notifying on the
given task, so the mutter bits can proceed with X11 startup.

One notable change is that we only start gsd-xsettings, instead of the
generic gnome-session-x11-services target. We do so as we have to wait
on a dbus name to appear in order to deem the initialization done, and
making it all depend on gsd-xsettings seems tidier.

Less notably, we also use ::shutdown-xserver to shutdown the related
services. Its major benefit is that it'd allow us to ensure the olderly
shutdown of those services, but it's unused at the moment.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/836

6 years agoibusManager: Use setup X11 display for ibus-x11
Carlos Garnacho [Sat, 29 Feb 2020 17:43:28 +0000 (18:43 +0100)]
ibusManager: Use setup X11 display for ibus-x11

(re)spawning ibus to get ibus-x11 will be part atm of Xwayland
initialization process. For it to be set up before the client
it needs using the GNOME_SETUP_DISPLAY.

https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/836

6 years agoUpdate Japanese translation
sicklylife [Sat, 29 Feb 2020 16:06:10 +0000 (16:06 +0000)]
Update Japanese translation

6 years agoUpdate Japanese translation
sicklylife [Sat, 29 Feb 2020 15:54:06 +0000 (15:54 +0000)]
Update Japanese translation

6 years agojs/ui: Subscribe touchpad gesture handlers to only touchpad events
Daniel van Vugt [Fri, 10 Jan 2020 07:44:35 +0000 (15:44 +0800)]
js/ui: Subscribe touchpad gesture handlers to only touchpad events

The touchpad gesture handlers were receiving all events, all the time.
This meant that even mouse movements were getting translated into
JavaScript calls and then discarded by the handlers, which wasted CPU.

Now we subscribe the touchpad gesture handlers to only touchpad events.

Prequisite: https://gitlab.gnome.org/GNOME/mutter/merge_requests/1000

Closes: https://gitlab.gnome.org/GNOME/mutter/issues/283
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/925

6 years agoUpdate Polish translation
Piotr Drąg [Sat, 29 Feb 2020 12:09:46 +0000 (13:09 +0100)]
Update Polish translation

6 years agoUpdate Persian translation
Danial Behzadi [Sat, 29 Feb 2020 02:24:13 +0000 (02:24 +0000)]
Update Persian translation

6 years agowindowManager: Show window resizing clone on "size-changed"
Jonas Dreßler [Fri, 28 Feb 2020 15:43:48 +0000 (16:43 +0100)]
windowManager: Show window resizing clone on "size-changed"

When a window is being resized by the compositor, with Wayland the
compositor first asks the window to change its size and emits the
"size-change" signal, and then emits the "size-changed" signal after
the window acknowledges the new size. To show a fancy resize animation,
gnome-shell creates a "screenshot" of the resizing window on the
"size-change" signal, and later animates that "screenshot" to the new
window size on the "size-changed" signal.

Now if a client is not responding to our requests asking it to change
its size, we get a "size-change" signal and start showing the
window-clone, but never a "size-changed" signal, animating and hiding
the clone again. This causes a so called "ghost window" that is shown
above everything else and never disappears again.

To fix that, start showing the window clone once we get the
"size-changed" signal instead of the "size-change" signal. This makes
sure the window actually updates its size and the clone is going to be
hidden again.

Fixes https://gitlab.gnome.org/GNOME/mutter/issues/1078

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1055

6 years agoUpdated Danish translation
Alan Mortensen [Fri, 28 Feb 2020 13:01:26 +0000 (14:01 +0100)]
Updated Danish translation

6 years agoUpdate Korean translation
Changwoo Ryu [Fri, 28 Feb 2020 09:00:39 +0000 (09:00 +0000)]
Update Korean translation

6 years agoUpdate Korean translation
Changwoo Ryu [Fri, 28 Feb 2020 07:19:46 +0000 (07:19 +0000)]
Update Korean translation

6 years agoUpdate Indonesian translation
Kukuh Syafaat [Fri, 28 Feb 2020 02:12:33 +0000 (02:12 +0000)]
Update Indonesian translation

6 years agoenvironment: reduce calls to g_time_zone_new_local()
Florian Müllner [Thu, 27 Feb 2020 21:46:44 +0000 (13:46 -0800)]
environment: reduce calls to g_time_zone_new_local()

Creating a new GTimeZone for the local timezone can be quite expensive if
done repeatedly. It requires an open(), mmap(), and parsing of
/etc/localtime.

This patch was provided by Florian, and I've tested it as far back as
3.28.4 to ensure that we are really reducing the number of open() calls
on the compositor thread.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1051

Signed-off-by: Christian Hergert <chergert@redhat.com>
6 years agoshell: fix typo in comment
Christian Hergert [Thu, 27 Feb 2020 02:59:31 +0000 (18:59 -0800)]
shell: fix typo in comment

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1050

6 years agoglobal: force fsync() to worker thread when saving state
Christian Hergert [Wed, 26 Feb 2020 22:46:20 +0000 (14:46 -0800)]
global: force fsync() to worker thread when saving state

The g_file_replace_contents_async() API can potentially call fsync() from
the thread calling into it upon completion. This can have disasterous
effects when run from the compositor main thread such as complete stalls.

This is a followup to 86a00b6872375a266449beee1ea6d5e94f1ebbcb which
assumed (like the rest of us) that the fsync() would be performed on the
thread that was doing the I/O operations.

You can verify this with an strace -e fsync and cause terminal to display
a command completed notification (eg: from a backdrop window).

This also fixes a lifecycle bug for the variant, as
g_file_replace_contents_async() does not copy the data during the operation
as that is the responsibility of the caller. Instead, we just use a GBytes
variant and reference the variant there.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1050

6 years agoci: Prohibit template strings in translatable files
Florian Müllner [Tue, 18 Feb 2020 16:08:23 +0000 (17:08 +0100)]
ci: Prohibit template strings in translatable files

Sadly, xgettext's dealing with template strings is abysimal, so we
had to stop using them in files with translatable strings.

Make sure we don't accidentally sneak in template strings again(*)
and enforce that rule in a CI job.

(*) easy "mistake", considering how much nicer they are than
    String.prototype.format()

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1016

6 years agoci: Check that files with translatable strings are listed in POTFILES
Florian Müllner [Tue, 18 Feb 2020 18:05:47 +0000 (19:05 +0100)]
ci: Check that files with translatable strings are listed in POTFILES

Also known as "Piotr Drąg Bot".

We will soon make sure that files processed by xgettext don't use template
strings. To make that check as adequate as possible, ensure that no source
code files are missing from POTFILES.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1016

6 years agocalendar-server: Remove unused defines
Florian Müllner [Tue, 18 Feb 2020 16:22:56 +0000 (17:22 +0100)]
calendar-server: Remove unused defines

The file doesn't contain any translatable strings, so the i18n
macros are unused.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/1016

6 years agoaltTab: Don't fade out thumbnails on destroy
Jonas Dreßler [Mon, 27 Jan 2020 22:42:28 +0000 (23:42 +0100)]
altTab: Don't fade out thumbnails on destroy

The thumbnails actor `this._thumbnails` has already been destroyed when
calling `_destroyThumbnails()` from the `destroy` signal handler because
it is a child actor of the AppSwitcherPopup. So stop destroying the
thumbnails separately (fading them out inside a destroy handler wouldn't
make sense anyway).

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/167

6 years agoswitcherPopup: Use correct scroll-direction property
Jonas Dreßler [Wed, 15 Jan 2020 16:04:07 +0000 (17:04 +0100)]
switcherPopup: Use correct scroll-direction property

The correct property for the scroll-direction with scrolling events is
`direction`, no `scroll_direction`. This fixes scrolling in the alt-tab
popup, which broke with the actorization changes.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/167

6 years agoswitcherPopup: Always return true when the popup finished early
Jonas Dreßler [Thu, 6 Dec 2018 17:05:39 +0000 (18:05 +0100)]
switcherPopup: Always return true when the popup finished early

When the switcherPopup was initiated successfully, we return true,
otherwise the WindowManager will try to destroy it. Since an early
release of the keystroke will also switch to another application and
close the switcher just fine, we should return true to indicate success
here.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/167

6 years agoswitcherPopup: Lookup index of items when hovering or clicking
Jonas Dreßler [Wed, 15 Jan 2020 15:19:41 +0000 (16:19 +0100)]
switcherPopup: Lookup index of items when hovering or clicking

Right now the index that gets selected on click and motion events is set
when connecting the event inside the addItem function. If items are
added or removed (for example when an application is closed by pressing
"q"), this index isn't valid anymore and has to be updated.

To fix this, use the items themselves instead of the index as arguments
for the event handlers and lookup the index of the item inside the event
handler.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/167

6 years agoswitcherPopup: Implement functions to add and remove accessible states
Jonas Dreßler [Thu, 26 Apr 2018 09:19:40 +0000 (11:19 +0200)]
switcherPopup: Implement functions to add and remove accessible states

Set the accessible states of the switcherList items by calling a
function instead of manipulating class-internal variables from outside
the class, which is considered bad practice.

The check whether the item at `_selectedIndex` exists can also be
removed since we always select a new index after an item was removed
(i.e. an app was closed) and destroy the alt-tab switcher right away if
no more items exist (see `SwitcherPopup._itemRemovedHandler`).

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/167

6 years agoswitcherPopup: Select correct item after removal of item
Jonas Dreßler [Wed, 25 Apr 2018 22:32:57 +0000 (00:32 +0200)]
switcherPopup: Select correct item after removal of item

If an item was removed, make sure the selected item is still selected or
select the last one if the selected item was removed.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/167

6 years agoswitcherPopup: Disable hover on scrolling events
Jonas Dreßler [Sun, 6 May 2018 20:49:52 +0000 (22:49 +0200)]
switcherPopup: Disable hover on scrolling events

Just like with keyboard events, disable hover on scrolling events. Mouse
movements should not mess up the selection while scrolling.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/167

6 years agoswitcherPopup: Swap Math.max and Math.min in _scrollToLeft
Jonas Dreßler [Wed, 25 Apr 2018 21:56:29 +0000 (23:56 +0200)]
switcherPopup: Swap Math.max and Math.min in _scrollToLeft

Limit the minimum and maximum value to scroll to inside the box to 0 and
the upper limit, for some reason this was done right in _scrollToRight,
but not in _scrollToLeft.

This fixes the behavior of scrolling to the left: Before, scrolling one
item to the left moved the view to the first element of the list (this
can make the selected element invisible in large lists). Instead, scroll
one item to the left, just like scrolling to the right works.

https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/167